package cn.nexd.location.utils.smoothness;

import java.util.List;

import cn.nexd.location.collector.bean.BluetoothCollectorResult;
import cn.nexd.location.collector.bean.WifiCollectorResult;

/**
 * Created by codngfish on 16/1/26.
 */
public class SmoothnessContext {

    private SmoothnessStrategy smoothnessWifiStrategy;
    private SmoothnessStrategy<BluetoothCollectorResult> smoothnessBluetoothStrategy;

    public SmoothnessContext(SmoothnessStrategy<WifiCollectorResult> smoothnessWifiStrategy, SmoothnessStrategy<BluetoothCollectorResult> smoothnessBluetoothStrategy) {
        this.smoothnessWifiStrategy = smoothnessWifiStrategy;
        this.smoothnessBluetoothStrategy = smoothnessBluetoothStrategy;
    }

    public List<WifiCollectorResult> executeSmoothnessWifi(List<WifiCollectorResult> inputWifiCollectorResults) {
        return smoothnessWifiStrategy.smoothness(inputWifiCollectorResults);
    }

    public List<BluetoothCollectorResult> executeSmoothnessBluetooth(List<BluetoothCollectorResult> inputBluetoothCollectorResults) {
        return smoothnessBluetoothStrategy.smoothness(inputBluetoothCollectorResults);
    }


}
